﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;


namespace Service.User
{
    // response server info
    public class ResponseServerInfo : IQueryInterface
    {
        public void GetData(string uid, Dictionary<string, object> p, ref Dictionary<string, object> d)
        {
            string device_id = p["deviceId"].ToString();
            int platOS = int.Parse(p["platOS"].ToString());

            d.Add("version",Consts.VERSION);
            d.Add("ab_url",Consts.AB_URL);
            if (platOS == 2)
            {
                d.Add("package_url", Consts.PACKAGE_IOS_URL);
            }
            else if (platOS == 3)
            {
                d.Add("package_url", Consts.PACKAGE_ANDROID_URL);
            }
            else
            {
                d.Add("package_url", "none");
            }
        }
    }
}
